+2007-05-02 Christian Persch <chpe@gnome.org>
+
+ * gtk/gtkpapersize.c: (gtk_paper_size_get_paper_sizes): Put only
+ GtkPaperSizes into the list, don't mix it with GtkPageSetups. Bug
+ #434861.
+
2007-05-02 Christian Persch <chpe@gnome.org>
* gtk/gtkpapersize.c: (gtk_paper_size_new_from_info),
GList *list = NULL;
guint i;
#ifdef G_OS_UNIX /* _gtk_load_custom_papers() only on Unix so far */
- if (include_custom)
- list = _gtk_load_custom_papers ();
+ if (include_custom)
+ {
+ GList *page_setups, *l;
+
+ page_setups = _gtk_load_custom_papers ();
+ for (l = page_setups; l != NULL; l = l->next)
+ {
+ GtkPageSetup *setup = (GtkPageSetup *) l->data;
+ GtkPaperSize *size;
+
+ size = gtk_page_setup_get_paper_size (setup);
+ list = g_list_prepend (list, gtk_paper_size_copy (size));
+ }
+
+ g_list_foreach (page_setups, (GFunc) g_object_unref, NULL);
+ g_list_free (page_setups);
+ }
#endif
for (i = 0; i < G_N_ELEMENTS (standard_names_offsets); ++i)
{